#ifndef FRIENDITEM_H
#define FRIENDITEM_H

#include <QWidget>
#include <QString>

#include "message.h"

namespace Ui {
class FriendItem;
}

class FriendItem : public QWidget
{
    Q_OBJECT

public:
    explicit FriendItem(QWidget *parent = nullptr);
    ~FriendItem();

    QString username() const;
    void setUsername(const QString &newUsername);

    QString userId() const;
    void setUserId(const QString &newUserId);

    void mousePressEvent(QMouseEvent *event);

signals:
    void signal_addChat(QString userId, Message::Type, QString username);

private:
    Ui::FriendItem *ui;

    QString m_userId;
    QString m_username;
};

#endif // FRIENDITEM_H
